#ifndef __TEXTURE_MANAGER_HPP__
#define __TEXTURE_MANAGER_HPP__

#include <map>
#include <string>
#include "TextureObject.hpp"

class HDRImageObject;

class TextureManager
{
public:
	static bool				createInstance();
	static void             destroyInstance();	
	static TextureManager*  getInstance();

	bool                    loadTexture(std::string fileName, TexType eTextureType = TEXTURE_STANDARD);
	bool                    loadTexture(const HDRImageObject* pHDR);
	bool                    unloadTexture(std::string fileName);
	const TextureObject*    getTexture(std::string fileName) const;

private:
	TextureManager(){};
	TextureManager(const TextureManager&){};

	~TextureManager(){};

	TextureManager& operator=(const TextureManager&){};

	bool                    isAlreadyLoaded(const std::string &fileName);

	static TextureManager*                  m_pInstance;
	std::map<std::string, TextureObject*>   m_texMap;
};

#endif